package com.data.common.util.jsonschema.validate;

import com.alibaba.fastjson.JSONObject;
import java.util.HashMap;
import java.util.Map;
import com.data.common.util.jsonschema.CommonProperty;
import com.data.modules.online.config.executor.DataBaseConst;

public class DictProperty extends CommonProperty {

    private static final long f21l = 3786503639885610767L;

    private String f22m;

    private String f23n;

    private String f24o;

    public String getDictCode() {
        return this.f22m;
    }

    public void setDictCode(String dictCode) {
        this.f22m = dictCode;
    }

    public String getDictTable() {
        return this.f23n;
    }

    public void setDictTable(String dictTable) {
        this.f23n = dictTable;
    }

    public String getDictText() {
        return this.f24o;
    }

    public void setDictText(String dictText) {
        this.f24o = dictText;
    }

    public DictProperty() {
    }

    public DictProperty(String key, String title, String dictTable, String dictCode, String dictText) {
        this.f2b = DataBaseConst.f474i;
        this.f5e = "sel_search";
        this.f1a = key;
        this.f6f = title;
        this.f22m = dictCode;
        this.f23n = dictTable;
        this.f24o = dictText;
    }

    public DictProperty(String key, String view, String title, String dictTable, String dictCode, String dictText) {
        this.f2b = DataBaseConst.f474i;
        this.f5e = view;
        this.f1a = key;
        this.f6f = title;
        this.f22m = dictCode;
        this.f23n = dictTable;
        this.f24o = dictText;
    }

    @Override
    public Map<String, Object> getPropertyJson() {
        HashMap hashMap = new HashMap();
        hashMap.put("key", getKey());
        JSONObject commonJson = getCommonJson();
        if (this.f22m != null) {
            commonJson.put("dictCode", this.f22m);
        }
        if (this.f23n != null) {
            commonJson.put("dictTable", this.f23n);
        }
        if (this.f24o != null) {
            commonJson.put("dictText", this.f24o);
        }
        hashMap.put("prop", commonJson);
        return hashMap;
    }
}
